<?=$this->headTitle('Результаты поиска');?>
<?php $this->headLink()->appendStylesheet('/twitterbootstrap/css/bootstrap.min.css')?>

<?= $this->headLink() ?>
<?php if(!empty($this->results)):?>
<?php foreach($this->results as $r):?>
<div id="searchresults">
<span class="category" >Категория: <a href="categories/<?=$r->category_name;?>"><?=$r->category_name;?></a></span>

<p><a href="<?=$this->url(array('id'=>$r->article_id),'catalog-display');?>"><?=$r->title;?></a></p>
    <div><a href="<?=$this->url(array('id'=>$r->article_id),'catalog-display');?>"><img src="images/articles/<?=$this->escape($r->img);?>"/></a></div>
<p class="description"><?=$r->description;?></p>
    <span style="float:right;padding-right:60px;font-size:14px;"><a href="<?=$this->url(array('id'=>$r->article_id),'catalog-display');?>">Читать далее &rarr;</a></span>
<p class="author">aвтор: <?=$r->author;?></p>
<p class="created_time">Дата создания: <?=$r->created_dt;?></p>
<hr class="line"><br/>
</div>
<?php endforeach;?>
<?php else:?>
<?=$this->searchform;?>
<p>Поиск не дал результатов</p>
<?php endif;?>
<div class="pagination" >
    <ul>
        <li style="font-size:12px;">
            <?=$this->pages;?>
        </li>
    </ul>
</div>
